package cn.wolfcode.mapper;

import cn.wolfcode.domain.Emp;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

@Mapper
public interface EmpMapper {


    List<Emp> selectCorrespond(@Param("gender") Integer gender,
                               @Param("name") String name,
                               @Param("begin") Date begin,
                               @Param("end") Date end);
    @Delete("""
        delete from emp where dept_id=#{id}
        """)
    void delete(Long id);

    void batchDelete(Long[] ids);

    void add(Emp emp);

    void update(Emp emp);

    Emp getOneById(Long id);

    Emp login(Emp loginemp);
}
